package com.foruo.learn.designmode.command.command;

import com.foruo.learn.designmode.command.ICommand;
import com.foruo.learn.designmode.command.IReceiver;

/**
 * 命令A - 用于执行 IReceiver
 * @author GaoYuan
 * @date 2018/11/12 上午11:35
 */
public class CommandA implements ICommand{

    private IReceiver receiver;

    public CommandA(IReceiver receiver){
        this.receiver = receiver;
    }

    @Override
    public void execute() {
        receiver.doExecute();
    }
}
